#include <cmath>
#include <iostream>

using namespace std;

long long qpow(int x, unsigned n) {
    long long ans = 1;

    while (n) {
        if (n % 2) ans *= x;
        x *= x;
        n /= 2;
    }

    return ans;
}

int main() {
    int x, n;
    cin >> x >> n;

    int ans = qpow(x, n);

    cout << ans << endl;

    return 0;
}
